<?php

/**
 * user actions.
 *
 * @package    www.furr.sk
 * @subpackage user
 * @author     Your name here
 * @version    SVN: $Id: actions.class.php 23810 2009-11-12 11:07:44Z Kris.Wallsmith $
 */
class userActions extends myActions
{
  public function preExecute()
  {
        if ($this->actionName != 'login')
            parent::preExecute();
  }

  public function executeIndex(sfWebRequest $request)
  {
  }

  public function executeLogin(sfWebRequest $request)
  {
      //$request->checkCSRFProtection();
      if ($request->isMethod('post'))
      {
          $post = $request->getPostParameter('user');
          $this->getUser()->login($post['login'], $post['password']);
      }
      $this->redirectToReferer();
  }
}
